Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apply existential any to protocol for Swift 6 #2283

Merged
merged 2 commits into from
Sep 8, 2024

Conversation

qwerty3345
Copy link
Contributor

Apply existential any to protocol for Swift 6

  • https://github.com/swiftlang/swift-evolution/blob/main/proposals/0335-existential-any.md

    After any is introduced, warnings will be added to guide programmers toward the new syntax. Finally, these warnings can become errors, or plain protocol names can be repurposed, in Swift 6.

  • I refactored by apply .enableUpcomingFeature("ExistentialAny")

    let package = Package(
        name: "Kingfisher",
        platforms: [.iOS(.v13), .macOS(.v10_15), .tvOS(.v13), .watchOS(.v6)],
        products: [
            .library(name: "Kingfisher", targets: ["Kingfisher"])
        ],
        targets: [
            .target(
                name: "Kingfisher",
                path: "Sources",
                swiftSettings: [
                    .enableUpcomingFeature("ExistentialAny")
                ]
            )
        ]
    )

@onevcat
Copy link
Owner

onevcat commented Sep 8, 2024

Perfect changes! Thank you!

@onevcat onevcat merged commit 550c2fe into onevcat:master Sep 8, 2024
8 checks passed
@qwerty3345 qwerty3345 deleted the apply-existential-any branch September 8, 2024 10:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants